package com.hifar.test.test.pojo.VO;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.hifar.plat.AopOption.Dict;
import com.hifar.plat.AopOption.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @author zhuWeiWei
 * @description TODO
 * @date 2025/4/21 16:10
 */
@Data
@ApiModel("试验导出VO")
public class HfEnvTestExportVO {
    /**
     * 主键
     */
    @ApiModelProperty(value = "主键")
    @TableId("id")
    @JSONField(name = "id")
    private String id;


    /**
     * 状态
     */
    @ApiModelProperty(value = "状态")
    @TableField("status")
    @JSONField(name = "status")
    private String status;

    /**
     * 密级
     */
    @ApiModelProperty(value = "密级")
    @Dict(dictCode = "hf_sys_datasecret")
    @TableField(value = "secret_level", fill = FieldFill.INSERT)
    @JSONField(name = "secretLevel")
    private String secretLevel;

    @Excel(name = "试验编号", sort = 1)
    @TableField("test_code")
    @JSONField(name = "testCode")
    private String testCode;

    @Excel(name = "状态", sort = 2)
    @ApiModelProperty("状态值")
    private String statusText;

    /**
     * 委托id
     */
    @Excel(name = "委托单号", sort = 3)
    @ApiModelProperty(value = "委托单号")
    private String entrustCode;

    @Excel(name = "委托部门", sort = 4)
    @ApiModelProperty(value = "委托部门")
    private String entrustCust;

    /**
     * 项目id
     */
    @ApiModelProperty(value = "项目id")
    @TableField("unit_id")
    @JSONField(name = "unitId")
    private String unitId;


    /**
     * 项目编码
     */
    @ApiModelProperty(value = "项目编码")
    @TableField("unit_code")
    @JSONField(name = "unitCode")
    private String unitCode;


    /**
     * 项目名称
     */
    @Excel(name = "试验项目", sort = 5)
    @ApiModelProperty(value = "项目名称")
    private String unitName;


    @ApiModelProperty("设备id")
    private String equipId;


    @Excel(name = "设备型号", sort = 6)
    @ApiModelProperty("设备型号")
    private String equipModel;

    @Excel(name = "设备内部名称", sort = 7)
    @ApiModelProperty("内部名称")
    private String innerName;

    @Excel(name = "设备名称", sort = 8)
    @ApiModelProperty("设备名称")
    private String equipName;

    @Excel(name = "设备编号", sort = 9)
    @ApiModelProperty("设备编号")
    private String equipCode;


    @Excel(name = "计量有效期", sort = 10, format = "yyyy-MM-dd")
    @ApiModelProperty("设备记录有效期时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date checkValid;

    @Excel(name = "计划开始时间", sort = 11, format = "yyyy-MM-dd HH:mm")
    @ApiModelProperty("计划开始时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date predictStartTime;


    @ApiModelProperty("计划结束时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Long predictUseTime;

    @Excel(name = "计划时长（小时）", sort = 12)
    private String predictUseTimeText;

    @Excel(name = "计划结束时间", sort = 13, format = "yyyy-MM-dd HH:mm")
    @ApiModelProperty("计划结束时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date predictEndTime;

    @Excel(name = "实际开始时间", sort = 14, format = "yyyy-MM-dd HH:mm")
    @ApiModelProperty("开始时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date realStartTime;

    @Excel(name = "实际结束时间", sort = 15, format = "yyyy-MM-dd HH:mm")
    @ApiModelProperty("结束时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date realEndTime;

    @Excel(name = "异常数量", sort = 16)
    @ApiModelProperty("异常数量")
    private Integer exceptionNum;

    /**
     * 备注
     */
    @ApiModelProperty(value = "备注")
    @TableField("remarks")
    @JSONField(name = "remarks")
    private String remarks;


    @TableField("row_sort")
    @JSONField(name = "rowSort")
    private Long rowSort;


    @TableField("img_path")
    @ApiModelProperty("移入照片路径")
    private String imgPath;


    @ApiModelProperty("温度")
    private BigDecimal temperature;
    @ApiModelProperty("湿度")
    private BigDecimal humidity;


}
